package com.nuonuo.middleware.controller;

import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * @author duan
 * @version 1.0
 * @date 2024/3/7 9:46
 */
@RestController
@RequestMapping(value = "/test")
public class TestController {

    @RequestMapping(value = "/cxfKp/reInvoice", method = RequestMethod.POST)
    public String reInvoice(@RequestBody Map<String, String> queryParam,
                                          @RequestHeader(value = "businessTaxNum") String businessTaxNum) {
        String orderNo = queryParam.get("orderno");
        String nextInvoiceCode = queryParam.get("nextInvoiceCode");
        String invoiceNumStart = queryParam.get("invoiceNumStart");
        return "OK, orderNo = " + orderNo;
    }
}
